From cfddb87d8a2d6971f4e7c669ab0b5678e6c5465c Mon Sep 17 00:00:00 2001 From: robertl Date: Mon, 19 Jun 2006 20:47:05 +0000 Subject: [PATCH] When converting HTML to space, convert newlines (and successive whitespace) to single space. --- util.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/util.c b/util.c index cb115058a..4ce933aa7 100644 --- a/util.c +++ b/util.c @@ -1194,10 +1194,15 @@ strip_html(const utf_string *in) } if (! tag[0]) { - if (*instr == '\n') + if (*instr == '\n') { *out++ = ' '; - else + do { + instr++; + } while (isspace(*instr)); + continue; + } else { *out++ = *instr; + } } else { if (taglen < (sizeof(tag)-1)) { -- 2.30.2